using System;
using System.Collections.Generic;
using System.Text;
using System.Reflection;
using NBusiness.CodeDom;
using NBusiness.CodeDom.Compiler;
using NBusiness.ESharp.Compiler;
using System.Resources;

namespace NBusiness.ESharp.Compiler
{
    public class ESharpBuildWarning : EntityBuildError
    {
        #region Static and constant
        private static ResourceManager _manager;

        static ESharpBuildWarning()
        {
            _manager = new ResourceManager("NBusiness.Properties.Resources", typeof(EntityBuildError).Assembly);
        } 
        #endregion

        public ESharpBuildWarning(
            ESharpErrorCode errorCode,
            EntityElement element)
            : base(errorCode.ToString(), _manager.GetString(errorCode.ToString()), element, EntityBuildErrorType.Warning)
        { }
    }
}
